package com.briup.jd2511.web02.controller;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/path") // 定义该类下面的所有方法添加path前缀
public class PathController {

    @RequestMapping(path={"/test","/hello","/hi"})
    public String test(){
        return "path test";
    }

    @RequestMapping(value = "/method",method = {RequestMethod.GET})
    public String method(){
        return "method test";
    }

}
